const odooModelName = 'res.company'

const values_default = {}

const domain_default = {}

const fields_default = {
  child_ids: { name: null, partner_id: null },
  user_ids: { name: null, login: null, email: null }
}

const filterItems = [
  { type: 'input', name: 'name___like', placeholder: '名称' }
]

const columns = [
  'name',
  'email',
  'phone',
  'website',
  'vat',

  // 'parent_id__name',
  // 'child_ids__count',
  'user_ids__count'
]

const table_expand = {
  field: 'user_ids__objects',
  type: 'table',
  columns: ['name', 'login', 'email']
}

const formItems = [
  'name',
  'email',
  'phone',
  'website',
  'vat' // 'parent_id'
]

const Model = {
  name: odooModelName,
  configs: {
    values_default,
    domain_default,
    fields_default,
    filterItems,
    columns,
    table_expand,
    formItems
  }
}

export default Model
